module SteelSpecific
    use ElementaryMath
    implicit none

contains
    !> \brief
    !!  $\kappa = \frac{1}{s}$
    !! \param
    !! \param
    !! \return
    !!
    !!
    pure function EvaluateDiffusivity(T) result (v)
        implicit none
        real(kind=8), intent(in) :: T
        real(kind=8) :: v
        v = Linear(-0.0325d0, 54.511d0, T)
    end function


    !> \brief
    !!
    !! \param
    !! \param
    !! \return
    !!
    !!
    pure function DerivativeDiffusivity(T) result (v)
        implicit none
        real(kind=8), intent(in) :: T
        real(kind=8) :: v
        v = -0.0325d0
    end function


    !> \brief
    !! Steel - from Marcus Vinicius Dissertation
    !! \param
    !! \param
    !! \return
    !!
    !!
    pure function EvaluateEspecificHeat(T) result (v)
        implicit none
        real(kind=8), intent(in) :: T
        real(kind=8) :: v
        if(T<=650) then
            v = Quadratic(-0.0052d0, 6.84d0, -1497.0d0, T)
        elseif(T > 650 .and. T <= 700) then
            v= Linear(2.28d0, -730.0d0, T)
        elseif(T > 700 .and. T <= 800) then
            v = Quadratic(-0.0674d0, 100.83d0, 36689.0d0, T)
        elseif(T > 800 .and. T <= 850) then
            v= Linear(-1.94d0, 2391.0d0, T)
        elseif(T > 850) then
            v = Quadratic(-0.0052d0, 6.84d0, -1497.0d0, T)
        end if
    end function


    !> \brief
    !!
    !! \param
    !! \param
    !! \return
    !!
    !!
    pure function DerivativeEspecificHeat(T) result (v)
        implicit none
        real(kind=8), intent(in) :: T
        real(kind=8) :: v
        if(T<=650) then
            v = Linear(-0.0052d0*2.0d0, 6.84d0, T)
        elseif(T > 650 .and. T <= 700) then
            v= 2.28d0
        elseif(T > 700 .and. T <= 800) then
            v = Linear(-0.0674d0*2.0d0, 100.83d0, T)
        elseif(T > 800 .and. T <= 850) then
            v= -1.94d0
        elseif(T > 850) then
            v = Linear(-0.0052d0*2.0d0, 6.84d0, T)
        end if
    end function


    pure function EvaluateThermalExpansionIsotropic(T) result (v)
        implicit none
        real(kind=8), intent(in) :: T
        real(kind=8) :: v

    end function

end module
